import java.util.Arrays;

public class TestDemo10 {
    public static int[] copyOf(int[] array){
        int[] ret = new int[5];
        for (int i = 0; i < array.length; i++) {
            ret[i] = array[i];
        }
        return ret;
    }
    public static void main(String[] args) {
        int[] array = {1,2,3,4,5};
        int[] ret = copyOf(array);
        System.out.println(Arrays.toString(array));
    }
}
